.class Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer$1;
.super Ljava/util/TimerTask;
.source "RhythmLayout.java"


# annotations
.annotation system Ldalvik/annotation/EnclosingMethod;
    value = Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;->startMonitor()V
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x0
    name = null
.end annotation


# instance fields
.field final synthetic this$1:Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;


# direct methods
.method constructor <init>(Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;)V
    .registers 2
    .param p1, "this$1"    # Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;

    .prologue
    .line 438
    iput-object p1, p0, Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer$1;->this$1:Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;

    invoke-direct {p0}, Ljava/util/TimerTask;-><init>()V

    return-void
.end method


# virtual methods
.method public run()V
    .registers 12

    .prologue
    .line 442
    iget-object v8, p0, Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer$1;->this$1:Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;

    # getter for: Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;->canShift:Z
    invoke-static {v8}, Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;->access$200(Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;)Z

    move-result v8

    if-eqz v8, :cond_7a

    .line 443
    const/4 v6, 0x0

    .line 444
    .local v6, "toPosition":I
    iget-object v8, p0, Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer$1;->this$1:Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;

    iget-object v8, v8, Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;->this$0:Lcom/brixd/niceapp/control/RhythmLayout;

    invoke-virtual {v8}, Lcom/brixd/niceapp/control/RhythmLayout;->getFirstVisibleItemPosition()I

    move-result v0

    .line 446
    .local v0, "currentFirstVisibleItemPos":I
    const/4 v3, 0x0

    .local v3, "includeLeftHiddenItem":Z
    const/4 v4, 0x0

    .line 447
    .local v4, "includeRightHiddenItem":Z
    const/4 v1, 0x0

    .line 448
    .local v1, "currentRelativePos":I
    iget-object v8, p0, Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer$1;->this$1:Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;

    iget v8, v8, Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;->x:F

    sget v9, Lcom/brixd/niceapp/control/RhythmLayout;->mEdgeSizeForShiftRhythm:I

    int-to-float v9, v9

    cmpg-float v8, v8, v9

    if-gtz v8, :cond_4c

    iget-object v8, p0, Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer$1;->this$1:Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;

    iget v8, v8, Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;->x:F

    const/4 v9, 0x0

    cmpl-float v8, v8, v9

    if-ltz v8, :cond_4c

    .line 449
    add-int/lit8 v8, v0, -0x1

    if-ltz v8, :cond_4a

    .line 450
    add-int/lit8 v6, v0, -0x1

    .line 451
    const/4 v3, 0x1

    .line 468
    :goto_2f
    move v5, v6

    .line 469
    .local v5, "scrollToPosition":I
    move v2, v1

    .line 470
    .local v2, "currentRelativePosFinal":I
    iget-object v8, p0, Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer$1;->this$1:Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;

    iget-object v8, v8, Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;->this$0:Lcom/brixd/niceapp/control/RhythmLayout;

    # invokes: Lcom/brixd/niceapp/control/RhythmLayout;->getVisibleRhythmViews(ZZ)Ljava/util/List;
    invoke-static {v8, v3, v4}, Lcom/brixd/niceapp/control/RhythmLayout;->access$400(Lcom/brixd/niceapp/control/RhythmLayout;ZZ)Ljava/util/List;

    move-result-object v7

    .line 471
    .local v7, "views":Ljava/util/List;, "Ljava/util/List<Landroid/view/View;>;"
    iget-object v8, p0, Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer$1;->this$1:Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;

    iget-object v8, v8, Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;->this$0:Lcom/brixd/niceapp/control/RhythmLayout;

    # getter for: Lcom/brixd/niceapp/control/RhythmLayout;->mHandler:Landroid/os/Handler;
    invoke-static {v8}, Lcom/brixd/niceapp/control/RhythmLayout;->access$700(Lcom/brixd/niceapp/control/RhythmLayout;)Landroid/os/Handler;

    move-result-object v8

    new-instance v9, Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer$1$1;

    invoke-direct {v9, p0, v2, v7, v5}, Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer$1$1;-><init>(Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer$1;ILjava/util/List;I)V

    invoke-virtual {v8, v9}, Landroid/os/Handler;->post(Ljava/lang/Runnable;)Z

    .line 486
    .end local v0    # "currentFirstVisibleItemPos":I
    .end local v1    # "currentRelativePos":I
    .end local v2    # "currentRelativePosFinal":I
    .end local v3    # "includeLeftHiddenItem":Z
    .end local v4    # "includeRightHiddenItem":Z
    .end local v5    # "scrollToPosition":I
    .end local v6    # "toPosition":I
    .end local v7    # "views":Ljava/util/List;, "Ljava/util/List<Landroid/view/View;>;"
    :cond_49
    :goto_49
    return-void

    .line 453
    .restart local v0    # "currentFirstVisibleItemPos":I
    .restart local v1    # "currentRelativePos":I
    .restart local v3    # "includeLeftHiddenItem":Z
    .restart local v4    # "includeRightHiddenItem":Z
    .restart local v6    # "toPosition":I
    :cond_4a
    move v6, v0

    goto :goto_2f

    .line 455
    :cond_4c
    iget-object v8, p0, Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer$1;->this$1:Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;

    iget v8, v8, Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;->x:F

    iget-object v9, p0, Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer$1;->this$1:Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;

    iget-object v9, v9, Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;->this$0:Lcom/brixd/niceapp/control/RhythmLayout;

    # getter for: Lcom/brixd/niceapp/control/RhythmLayout;->screenWidth:I
    invoke-static {v9}, Lcom/brixd/niceapp/control/RhythmLayout;->access$100(Lcom/brixd/niceapp/control/RhythmLayout;)I

    move-result v9

    sget v10, Lcom/brixd/niceapp/control/RhythmLayout;->mEdgeSizeForShiftRhythm:I

    sub-int/2addr v9, v10

    int-to-float v9, v9

    cmpl-float v8, v8, v9

    if-ltz v8, :cond_49

    .line 456
    iget-object v8, p0, Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer$1;->this$1:Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;

    iget-object v8, v8, Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;->this$0:Lcom/brixd/niceapp/control/RhythmLayout;

    # getter for: Lcom/brixd/niceapp/control/RhythmLayout;->mLinearLayout:Landroid/widget/LinearLayout;
    invoke-static {v8}, Lcom/brixd/niceapp/control/RhythmLayout;->access$300(Lcom/brixd/niceapp/control/RhythmLayout;)Landroid/widget/LinearLayout;

    move-result-object v8

    invoke-virtual {v8}, Landroid/widget/LinearLayout;->getChildCount()I

    move-result v8

    add-int/lit8 v9, v0, 0x7

    add-int/lit8 v9, v9, 0x1

    if-lt v8, v9, :cond_77

    .line 457
    add-int/lit8 v6, v0, 0x1

    .line 458
    const/4 v4, 0x1

    .line 459
    const/4 v1, 0x7

    goto :goto_2f

    .line 461
    :cond_77
    move v6, v0

    .line 462
    const/4 v1, 0x6

    goto :goto_2f

    .line 484
    .end local v0    # "currentFirstVisibleItemPos":I
    .end local v1    # "currentRelativePos":I
    .end local v3    # "includeLeftHiddenItem":Z
    .end local v4    # "includeRightHiddenItem":Z
    .end local v6    # "toPosition":I
    :cond_7a
    iget-object v8, p0, Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer$1;->this$1:Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;

    const/4 v9, 0x1

    # setter for: Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;->canShift:Z
    invoke-static {v8, v9}, Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;->access$202(Lcom/brixd/niceapp/control/RhythmLayout$ShiftRhythmMonitorTimer;Z)Z

    goto :goto_49
.end method
